<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>{log_name} : {log_account_no}</title>
<link rel="shortcut icon" href="{dir_image}favicon.ico">
<link rel="stylesheet" type="text/css" href="{dir_css}Global.css" />
<link rel="stylesheet" type="text/css" href="{dir_css}Popup.css" />
<link rel="stylesheet" type="text/css" href="{dir_css}Registrar.css" />
<link rel="stylesheet" type="text/css" href="{dir_css}Administrator.css" />

<script type="text/javascript" src="{dir_js}jquery.min.js"></script>
<script type="text/javascript" src="{dir_js}Global.js"></script>
<script type="text/javascript">
	<!--
	
	$(document).ready(function() {
			
		searchBox('searchBox');
		
		$('#searchButton').click(function() {
			$('#search_form').submit();
		});
		
		$('#select_section').on('change', function() {
			$('#search_form').submit();
		});
		
		
		
	});	
	
	function is_int(value){ 
	   return !isNaN(parseInt(value * 1));
	}
	function saveGradeInput(strStud, strSubj, strCourse, strSem, strYear) {
		
		if ( $('#input_transfer'+strStud).val() == '' || $('#input_transfer'+strStud).val() <= 0 ) {
			$('#input_transfer'+strStud).addClass('transfery-warning-input');
			return false;
		}
		else {
			
			var inputValue = !isNaN(parseInt($('#input_transfer'+strStud).val() * 1));
			
			if ( inputValue == true || $('#input_transfer'+strStud).val() == 'INC' || $('#input_transfer'+strStud).val() == 'DRP') {
				$('#input_transfer'+strStud).removeClass('transfery-warning-input');
				$.post('request.php', {AJAXPost:'SaveStudentGrades', stud_id:strStud, subj_id:strSubj, course_id:strCourse, sem_id:strSem, year_id:strYear, grades:$('#input_transfer'+strStud).val(), stud_subj_id:$('#id_transfer'+strStud).val() }, function(res) {
					$('#id_transfer'+strStud).val(res.stud_subj_id);
					$('#transfery_grades'+strStud).html(res.grade_convertion);
					
					if ( $('#input_transfer'+strStud).val() != '') {
						if ( $('#input_transfer'+strStud).val() == 'INC' )
							subjDescription = '<span class="font-red">Incomplete</span>';
						else if ( $('#input_transfer'+strStud).val() == 'DRP' )
							subjDescription = '<span class="font-red">Drop</span>';
						else {
							subjDescription = res.description;
						}
					}
					$('#transfery_pfid'+strStud).html(subjDescription);
					
				
				}, 'json');
			}
			else {
				$('#input_transfer'+strStud).addClass('transfery-warning-input');
				return false;
			}
			
		}
	}
		
	//-->
</script>

</head>

<body>
<!-- POPUP -->{page_popup}<!-- POPUP END -->
<!-- TOP HEADER -->{page_header}<!-- TOP HEADER END -->
	<div class="main-content">
	
		<table width="0" border="0" cellspacing="0" cellpadding="0">
			<tr valign="top" align="left">
				<td width="220">
					{prof_sub_menu}
				</td>
				<td width="755">
					<div class="page-sub-content">
					<div class="float-right-back"><a href="?page=ProfStudents"><img src="{dir_image}icon/back.png" border="0" class="cursor-pointer"/></a></div>
					<div class="ann-top-label">{subject_desc} ({subject_code})</div>
					<form method="get" enctype="multipart/form-data" action="" id="search_form">
						<input type="hidden" name="page" 	value="{page}"  />
						<input type="hidden" name="slid" 	value="{slid}"  />
						<input type="hidden" name="psid" 	value="{psid}"  />
						<input type="hidden" name="sid" 	value="{sid}"  />
						<input type="hidden" name="hash" 	value="{hash}"  />
						<div class="search-image-design">
							<div class="search-image-design-other">
								<div class="search-image-design-other-label">Section:</div>
								<div class="search-image-design-other-selector">
									{select_section}
								</div>
								<div class="search-image-design-other-colon">::</div>
							</div>
							<div class="search-image-design-first"></div>
							<div class="search-image-design-middle"><input type="text" name="search" id="searchBox" class="text-search login-color-aaa" value="{search}"/></div>
							<div class="search-image-design-end" id="searchButton"></div>
							<div class="search-image-design-results">{results} Students</div>
						</div>
					</form>
					<div class="note-description">
						<span class="font-red"><strong>NOTE:</strong></span> Write <strong>DRP</strong> for DROP &nbsp;&nbsp;&nbsp;|&nbsp;&nbsp;&nbsp;<strong>INC</strong> for INCOMPLETE</div>
					<table width="750" border="0" cellspacing="0" cellpadding="0">
						<tr class="tr-header">
							<td width="15" class="td-label">&nbsp;</td>
							<td width="85" class="td-label">Student #</td>
							<td width="260" class="td-label">Name</td>
							<td width="80" class="td-label">Section</td>
							<td width="90" class="td-label">Final Grade</td>
							<td width="100" class="td-label">&nbsp;</td>
							<td width="120" class="td-label">&nbsp;</td>
						</tr>
						<!-- BEGIN students -->
							<tr {bgcolor} class="hover-light">
								<td class="td-record"><strong>{numbering}.</strong></td>
								<td class="td-record">{stud_no}</td>
								<td class="td-record">{name}</td>
								<td class="td-record">{section}</td>
								<td class="td-record">{grades}</td>
								<td class="td-record" align="center">{convertion}</td>
								<td class="td-record" align="center">{description}</td>
							</tr>
						<!-- END students -->
						
						<tr><td colspan="7" height="12"></td></tr>
						<tr>
							<td colspan="7" align="right" height="20">{pagination}</td>
						</tr>
					</table>
					
					
					</div>
				</td>
			</tr>
		</table>
		
	</div>
<!-- FOOTER -->{page_footer}<!-- FOOTER -->
</body>
</html>
